<form id="add-form" class="form-horizontal" style="position:relative;background: #fff" role="form" data-toggle="validator" method="POST" action="">
    
    <div class="panel-body">
        <div id="myTabContent" class="tab-content" >
            <div class="tab-pane fade active in" id="tabs_0">
                <input type="hidden" name="row[id]" value="" class="form-control" data-rule="" data-tip="ID"  />

                <div class="form-group">
                    <label for="c-number" class="control-label col-xs-12 col-sm-2">位置描述:</label>
                    <div class="col-xs-12 col-sm-8" id="div-number">
                        <label for="c-number" class="control-label col-xs-12 col-sm-2"></label>
                        <div style="margin-top:-2px">
                            <select id="c-number" data-rule="require" class="form-control" name="row[number]">
                            </select>
                        </div>
                    </div>
                </div>

                   <!-- 图片组管理区域 -->
                   <div class="form-group">
                        <label class="control-label col-xs-12 col-sm-2">图片管理:</label>
                        <div class="col-xs-12 col-sm-10">
                            <div class="panel panel-default">
                                <div class="panel-heading">
                                    <h4 class="panel-title">
                                        <i class="fa fa-images"></i> 轮播图片设置 
                                        <small class="text-muted">（最多可添加5张图片）</small>
                                    </h4>
                                </div>
                                <div class="panel-body" style="padding:15px 25px;">
                                    <div id="slider-images-container">
                                        <!-- 图片组1 -->
                                        <div class="slider-image-group" data-index="1">
                                            <div class="panel panel-info">
                                                <div class="panel-heading">
                                                    <h5 class="panel-title">
                                                        <i class="fa fa-image"></i> 图片 1
                                                        <button type="button" class="btn btn-xs btn-danger pull-right remove-image-group" style="margin-top: -2px;">
                                                            <i class="fa fa-trash"></i> 删除
                                                        </button>
                                                    </h5>
                                                </div>
                                                <div class="panel-body">
                                                    <div class="row">
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片标题:</label>
                                                                <input type="text" name="images[1][title]" class="form-control" placeholder="请输入图片标题" data-tip="图片标题" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片链接:</label>
                                                                <input type="text" name="images[1][href]" class="form-control" placeholder="请输入图片链接" data-tip="图片链接" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片地址:</label>
                                                                <div class="input-group">
                                                                    <input type="text" name="images[1][src]" class="form-control image-src-input" placeholder="请选择图片" data-tip="图片地址"  />
                                                                    <div class="input-group-btn">
                                                                        <button type="button" class="btn btn-danger plupload" data-input-id="images-1-src" data-mimetype="image/*" data-width="357" data-height="174" data-multiple="false" data-preview-id="p-images-1">
                                                                            <i class="fa fa-upload"></i>
                                                                        </button>
                                                                        <button type="button" class="btn btn-success collect-btn" data-group-index="1">
                                                                            <i class="fa fa-download"></i> 抓取
                                                                        </button>
                                                                    </div>
                                                                </div>
                                                                <ul class="row list-inline plupload-preview" id="p-images-1" style="margin-top: 10px;"></ul>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                        
                                        <!-- 图片组2 -->
                                        <div class="slider-image-group" data-index="2" style="display: none;">
                                            <div class="panel panel-info">
                                                <div class="panel-heading">
                                                    <h5 class="panel-title">
                                                        <i class="fa fa-image"></i> 图片 2
                                                        <button type="button" class="btn btn-xs btn-danger pull-right remove-image-group" style="margin-top: -2px;">
                                                            <i class="fa fa-trash"></i> 删除
                                                        </button>
                                                    </h5>
                                                </div>
                                                <div class="panel-body">
                                                    <div class="row">
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片标题:</label>
                                                                <input type="text" name="images[2][title]" class="form-control" placeholder="请输入图片标题" data-tip="图片标题" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片链接:</label>
                                                                <input type="text" name="images[2][href]" class="form-control" placeholder="请输入图片链接" data-tip="图片链接" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片地址:</label>
                                                                <div class="input-group">
                                                                    <input type="text" name="images[2][src]" class="form-control image-src-input" placeholder="请选择图片" data-tip="图片地址" />
                                                                    <div class="input-group-btn">
                                                                        <button type="button" class="btn btn-danger plupload" data-input-id="images-2-src" data-mimetype="image/*" data-width="357" data-height="174" data-multiple="false" data-preview-id="p-images-2">
                                                                            <i class="fa fa-upload"></i>
                                                                        </button>
                                                                        <button type="button" class="btn btn-success collect-btn" data-group-index="2">
                                                                            <i class="fa fa-download"></i> 抓取
                                                                        </button>
                                                                    </div>
                                                                </div>
                                                                <ul class="row list-inline plupload-preview" id="p-images-2" style="margin-top: 10px;"></ul>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                        
                                        <!-- 图片组3 -->
                                        <div class="slider-image-group" data-index="3" style="display: none;">
                                            <div class="panel panel-info">
                                                <div class="panel-heading">
                                                    <h5 class="panel-title">
                                                        <i class="fa fa-image"></i> 图片 3
                                                        <button type="button" class="btn btn-xs btn-danger pull-right remove-image-group" style="margin-top: -2px;">
                                                            <i class="fa fa-trash"></i> 删除
                                                        </button>
                                                    </h5>
                                                </div>
                                                <div class="panel-body">
                                                    <div class="row">
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片标题:</label>
                                                                <input type="text" name="images[3][title]" class="form-control" placeholder="请输入图片标题" data-tip="图片标题" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片链接:</label>
                                                                <input type="text" name="images[3][href]" class="form-control" placeholder="请输入图片链接" data-tip="图片链接" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片地址:</label>
                                                                <div class="input-group">
                                                                    <input type="text" name="images[3][src]" class="form-control image-src-input" placeholder="请选择图片" data-tip="图片地址" />
                                                                    <div class="input-group-btn">
                                                                        <button type="button" class="btn btn-danger plupload" data-input-id="images-3-src" data-mimetype="image/*" data-width="357" data-height="174" data-multiple="false" data-preview-id="p-images-3">
                                                                            <i class="fa fa-upload"></i>
                                                                        </button>
                                                                        <button type="button" class="btn btn-success collect-btn" data-group-index="3">
                                                                            <i class="fa fa-download"></i> 抓取
                                                                        </button>
                                                                    </div>
                                                                </div>
                                                                <ul class="row list-inline plupload-preview" id="p-images-3" style="margin-top: 10px;"></ul>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                        
                                        <!-- 图片组4 -->
                                        <div class="slider-image-group" data-index="4" style="display: none;">
                                            <div class="panel panel-info">
                                                <div class="panel-heading">
                                                    <h5 class="panel-title">
                                                        <i class="fa fa-image"></i> 图片 4
                                                        <button type="button" class="btn btn-xs btn-danger pull-right remove-image-group" style="margin-top: -2px;">
                                                            <i class="fa fa-trash"></i> 删除
                                                        </button>
                                                    </h5>
                                                </div>
                                                <div class="panel-body">
                                                    <div class="row">
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片标题:</label>
                                                                <input type="text" name="images[4][title]" class="form-control" placeholder="请输入图片标题" data-tip="图片标题" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片链接:</label>
                                                                <input type="text" name="images[4][href]" class="form-control" placeholder="请输入图片链接" data-tip="图片链接" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片地址:</label>
                                                                <div class="input-group">
                                                                    <input type="text" name="images[4][src]" class="form-control image-src-input" placeholder="请选择图片" data-tip="图片地址" />
                                                                    <div class="input-group-btn">
                                                                        <button type="button" class="btn btn-danger plupload" data-input-id="images-4-src" data-mimetype="image/*"  data-width="357" data-height="174" data-multiple="false" data-preview-id="p-images-4">
                                                                            <i class="fa fa-upload"></i>
                                                                        </button>
                                                                        <button type="button" class="btn btn-success collect-btn" data-group-index="4">
                                                                            <i class="fa fa-download"></i> 抓取
                                                                        </button>
                                                                    </div>
                                                                </div>
                                                                <ul class="row list-inline plupload-preview" id="p-images-4" style="margin-top: 10px;"></ul>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                        
                                        <!-- 图片组5 -->
                                        <div class="slider-image-group" data-index="5" style="display: none;">
                                            <div class="panel panel-info">
                                                <div class="panel-heading">
                                                    <h5 class="panel-title">
                                                        <i class="fa fa-image"></i> 图片 5
                                                        <button type="button" class="btn btn-xs btn-danger pull-right remove-image-group" style="margin-top: -2px;">
                                                            <i class="fa fa-trash"></i> 删除
                                                        </button>
                                                    </h5>
                                                </div>
                                                <div class="panel-body">
                                                    <div class="row">
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片标题:</label>
                                                                <input type="text" name="images[5][title]" class="form-control" placeholder="请输入图片标题" data-tip="图片标题" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片链接:</label>
                                                                <input type="text" name="images[5][href]" class="form-control" placeholder="请输入图片链接" data-tip="图片链接" />
                                                            </div>
                                                        </div>
                                                        <div class="col-md-4">
                                                            <div class="form-group" style="margin-left:8px;margin-right:8px;">
                                                                <label class="control-label">图片地址:</label>
                                                                <div class="input-group">
                                                                    <input type="text" name="images[5][src]" class="form-control image-src-input" placeholder="请选择图片" data-tip="图片地址" />
                                                                    <div class="input-group-btn">
                                                                        <button type="button" class="btn btn-danger plupload" data-input-id="images-5-src" data-mimetype="image/*" data-width="357" data-height="174" data-multiple="false" data-preview-id="p-images-5">
                                                                            <i class="fa fa-upload"></i>
                                                                        </button>
                                                                        <button type="button" class="btn btn-success collect-btn" data-group-index="5">
                                                                            <i class="fa fa-download"></i> 抓取
                                                                        </button>
                                                                    </div>
                                                                </div>
                                                                <ul class="row list-inline plupload-preview" id="p-images-5" style="margin-top: 10px;"></ul>
                                                            </div>
                                                        </div>
                                                    </div>
                                                </div>
                                            </div>
                                        </div>
                                    </div>
                                    
                                    <!-- 添加图片按钮 -->
                                    <div class="text-center" style="margin-top: 15px;">
                                        <button type="button" id="add-image-group" class="btn btn-success">
                                            <i class="fa fa-plus"></i> 添加图片
                                        </button>
                                        <small class="text-muted">（已添加 <span id="image-count">1</span> / 5 张图片）</small>
                                    </div>
                                </div>
                            </div>
                        </div>
                   </div>
                <div class="form-group layer-footer">
                    <label class="control-label col-xs-12 col-sm-2"></label>
                    <div class="col-xs-12 col-sm-8">
                        <button type="submit" class="btn btn-success btn-embossed disabled">{:__('OK')}</button>
                        <button type="reset" class="btn btn-default btn-embossed">{:__('Reset')}</button>
                    </div>
                </div>
            </div>
            
        </div>
    </div>
</form>
